package system

import (
	"github.com/gin-gonic/gin"
	v1 "main.go/api/v1"
	"main.go/middleware"
)

type UploadFileRouter struct{}

func (r *UploadFileRouter) InitUploadFileRouter(Router *gin.RouterGroup) {
	privateAdminGroup := Router.Group("upload").Use(middleware.Auth("admin"))
	privateGroup := Router.Group("upload").Use(middleware.IsAuth())
	api := v1.ApiGroupApp.SystemApiGroup.UploadFileApi
	{
		privateAdminGroup.POST("delete", api.Delete) // 删
		privateAdminGroup.POST("list", api.List)     // 查
		privateAdminGroup.POST("update", api.Update) // 改

	}
	{
		privateGroup.POST("create", api.Create)
	}
}
